//
//  WBTestViewController.swift
//  WeiBo
//
//  Created by liushaohua on 16/10/22.
//  Copyright © 2016年 liushaohua. All rights reserved.
//

import UIKit

class WBTestViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        self.view.backgroundColor = UIColor.green
        
        setupUI()
    }

    func pushBtnClick(){
    
        let testVC = WBTestViewController()
        
        self.navigationController?.pushViewController(testVC, animated: true)
    
    }
    
    //MARK: 设置右边push按钮 和中间标题
    func setupUI(){
        self.navigationItem.rightBarButtonItem = UIBarButtonItem(setHighlightedImg: nil, title: "PUSH", target: self, action: #selector(pushBtnClick))
        
        self.navigationItem.title = "第\(navigationController?.childViewControllers.count ?? 0)个控制器"
    }
  


}
